		function goHome (){
			return createNewCookie("content","INDEX");
		}

		function goNews (){
			return createNewCookie("content","NEWS");
		}

		function goSystem (){
			return createNewCookie("content","SYSTEM");
		}

		function goLogin (){
			return createNewCookie("content","LOGIN");
		}

		function goAbout (){
			return createNewCookie("content","ABOUT");
		}

		function goMap (){
			return createNewCookie("content","SITE_MAP");
		}

		function goLastUpd(){
			return createNewCookie("content","LAST_UPDATES");	
		}

		function goRegister(){
			createNewCookie("loginOrRegistration","REGISTRATION");	
			return location.href="loginOrRegister.jsp"
		}

		function Enter(){
			createNewCookie("loginOrRegistration","LOGIN");	
		}

		function Exit(){
			createNewCookie("loginOrRegistration","EXIT");	
		}

		function doRegistration(){
			createNewCookie("loginOrRegistration","DO_REGISTRATION");	
		}

		function createNextDate(){
			var interval = 1000*60*60*24;
			var intervalDate = new Date(interval);
			var curDate = new Date();
			return new Date(intervalDate.getTime()+curDate.getTime());
		}

		function createNewCookie(cookieName,cookieValue){
			document.cookie=cookieName+"="+cookieValue+"; expires="+createNextDate+"; path=/";
			return location.href="index.jsp"
		}

		function cookieFormForWork(value){
			return createNewCookie("formForWork",value);
		}

		function chooseSystemFunction(value){
			return createNewCookie("system",value);
		}

		function checkPasswordForASCII(){
			var passField=document.getElementsByName('passwordField')[0];
			var pass=passField.value;
			var msg;
			var spanColor;
			if (pass.length!=0){
				var good=true;
				for (var i = 0; i < pass.length; i++) {
					var next=pass.charCodeAt(i);
					if (!(((next>47)&&(next<58))||((next>64)&&(next<91))||((next>96)&&(next<122)))){
						good=false;
						break;
					}
				};
				if (good){
					msg='Пароль подходит.';
					spanColor='#0099FF';
				} else{
					msg='Допустимые символы: A-Z,a-z,0-9.';
					spanColor='#FF0000';
				}
			} else {
				msg="";
			}
			var span=document.getElementsByName('ASCIIResult')[0];
			span.style.color=spanColor;
			span.innerHTML=msg;
			checkConfirmed();
		}

		function checkConfirmed(){
			var pass=document.getElementsByName('passwordField')[0].value;
			var passConfirmed=document.getElementsByName('confirmField')[0].value;
			var msg;
			var spanColor;
			if ((pass.length!=0)||(passConfirmed.length!=0)){
				if (pass===passConfirmed){
					msg='Пароли совпадают.';
					spanColor='#0099FF';
				} else {
					msg='Пароли не совпадают!!!';
					spanColor='#FF0000';
				}
			} else {
				msg="";
			}
			
			var span=document.getElementsByName('checkResult')[0];
			span.style.color=spanColor;
			span.innerHTML=msg;
		}